import Vue from 'vue'
import VueRouter from 'vue-router'
import Hello from '../components/Hello.vue'
import Home from '../components/Home/Home.vue'
import Home2 from '../components/Home/Home2.vue'
import Artilce from '../components/Page/Article.vue'
Vue.use(VueRouter)

  const routes = [
  {
    path: '/',
    name: 'Hello',
    component: Hello
  },{
    path: '/home',
    name: 'Home',
    component: Home,
    redirect: '/Home2',
    children:[
      {path:'/home2',component: Home2,},
      {path:'/article', component: Artilce, name:'article'}
    ]
  }
]

const router = new VueRouter({
  routes
})

export default router
